package com.wonderful.wedding.repository;

import com.wonderful.wedding.mapper.GroupPersonMappingMapper;
import com.wonderful.wedding.model.Person;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

@Repository
public class GroupPersonMappingRepository {

    @Autowired
    private GroupPersonMappingMapper mapper;

    public Person findPersonByGroupAndPerson(int groupName, int personName) {
        return mapper.findByGroupAndPerson(groupName, personName);
    }

    public int create(int groupId, int personId) {
        return mapper.create(groupId, personId);
    }
}
